Skip to content

⬆️ dep-bump(python): 3.11+ - #75

Merged
nstarman merged 3 commits into
GalacticDynamics:mainfrom
nstarman:optype
Feb 22, 2026
Merged

⬆️ dep-bump(python): 3.11+#75
nstarman merged 3 commits into
GalacticDynamics:mainfrom
nstarman:optype

Conversation

@nstarman

@nstarman nstarman commented Jan 28, 2026

Copy link
Copy Markdown
Contributor

According to SPEC-0 we shouldn't be building towards Python 3.10.
3.11 is even too old, but we'll hang on to that for a bit while plum is fixing 3.14 compatibility.
Simplifies custom Protocols with stable optype versions.

@nstarman nstarman added this to the v0.9.0 milestone Jan 28, 2026
Copilot AI review requested due to automatic review settings January 28, 2026 15:53
@github-actions github-actions Bot added 🔧 Add / update configuration Add or update configuration files. ➕ Add a dependency Add a dependency. 💥 Introduce breaking changes Introduce breaking changes. labels Jan 28, 2026
@codecov

codecov Bot commented Jan 28, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.32%. Comparing base (c1bbc41) to head (6bc972d).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #75      +/-   ##
==========================================
- Coverage   97.36%   97.32%   -0.05%     
==========================================
  Files          12       12              
  Lines         304      299       -5     
==========================================
- Hits          296      291       -5     
  Misses          8        8              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR replaces the internal CanCopyReplace Protocol with the equivalent opt.copy.CanReplaceSelf from the optype library. This is a breaking change that removes a previously exported type from the public API.

Changes:

  • Added optype>=0.9.3 as a new dependency with version-specific constraints (0.9.3 for Python <3.11, 0.15.0 for Python ≥3.11)
  • Removed the CanCopyReplace Protocol class and exported type from the codebase
  • Updated all usages of CanCopyReplace to use opt.copy.CanReplaceSelf instead

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
uv.lock Added optype dependency with appropriate version constraints for different Python versions
pyproject.toml Added optype>=0.9.3 to project dependencies
src/dataclassish/_src/types.py Removed CanCopyReplace Protocol definition and export, removed now-unused Self import
src/dataclassish/_src/register_copyreplace.py Updated to import and use opt.copy.CanReplaceSelf instead of local CanCopyReplace; updated docstring
src/dataclassish/init.py Removed CanCopyReplace from public exports and imports

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions github-actions Bot added the ⬆️ Upgrade dependencies Upgrade dependencies. label Feb 22, 2026
@nstarman nstarman changed the title 💥 boom: replace Protocols with optype equivalents ⬆️ dep-bump(python): 3.11+ Feb 22, 2026
@nstarman
nstarman requested a review from a team as a code owner February 22, 2026 17:43
@github-actions github-actions Bot added the 👷 Add / update CI build system Add or update CI build system. label Feb 22, 2026
Signed-off-by: nstarman <nstarman@users.noreply.github.com>
Signed-off-by: nstarman <nstarman@users.noreply.github.com>
@nstarman
nstarman merged commit 29ad827 into GalacticDynamics:main Feb 22, 2026
20 checks passed
@nstarman
nstarman deleted the optype branch February 22, 2026 18:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

➕ Add a dependency Add a dependency. 👷 Add / update CI build system Add or update CI build system. 🔧 Add / update configuration Add or update configuration files. 💥 Introduce breaking changes Introduce breaking changes. ⬆️ Upgrade dependencies Upgrade dependencies.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants